<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
  <title>校园管理系统布局 - Layui</title>
  <link rel="stylesheet" th:href="@{/layui/css/layui.css}">
  <link rel="stylesheet" th:href="@{/layer/mobile/need/layer.css}">
  <style>
    .layui-table-view .layui-form-checkbox[lay-skin=primary] i {
      margin-top:8px;
    }
    .layui-btn-group{
      position: relative;
      right: 350px;
    }
    #export{
      height: 38px;
    }
    #import{
      height: 38px;
    }
    #excel{
      position: relative;
      top: 20px;
    }
    #count{
      width: 30px;
      text-align: center;
      border: 1px solid sandybrown;
    }
    #increase,#reduce{
      width: 20px;
      border: 1px solid sandybrown;
    }
  </style>
</head>
<body>
<div>
  <!--    <input id="basePath" hidden value="/springboot">-->
</div>
<div class="layui-layout layui-layout-admin">
  <div class="layui-header">
    <div class="layui-logo layui-hide-xs layui-bg-black">校园应用系统</div>
    <!-- 头部区域（可配合layui 已有的水平导航） -->
    <ul class="layui-nav layui-layout-left">
      <!-- 移动端显示 -->
      <li class="layui-nav-item layui-show-xs-inline-block layui-hide-sm" lay-header-event="menuLeft">
        <i class="layui-icon layui-icon-spread-left"></i>
      </li>

      <li class="layui-nav-item layui-hide-xs"><a href="">nav 1</a></li>
      <li class="layui-nav-item layui-hide-xs"><a href="">nav 2</a></li>
      <li class="layui-nav-item layui-hide-xs"><a href="">nav 3</a></li>
      <li class="layui-nav-item">
        <a href="javascript:;">nav groups</a>
        <dl class="layui-nav-child">
          <dd><a href="">menu 11</a></dd>

        </dl>
      </li>
    </ul>
    <ul class="layui-nav layui-layout-right">
      <li class="layui-nav-item"><a href="javascript:void(0);">今天是<span id="day"></span>&nbsp;&nbsp;&nbsp;
        <span id="time"></span>
      </a></li>
      <li class="layui-nav-item layui-hide layui-show-md-inline-block">
        <a href="javascript:;">
          <img src="//tva1.sinaimg.cn/crop.0.0.118.118.180/5db11ff4gw1e77d3nqrv8j203b03cweg.jpg" class="layui-nav-img">

        </a>
        <dl class="layui-nav-child">
          <dd><a href="">个人资料</a></dd>
          <dd><a href="">设置</a></dd>
          <dd><a href="">退出系统</a></dd>
        </dl>
      </li>
      <li class="layui-nav-item" lay-header-event="menuRight" lay-unselect>
        <a href="javascript:;">
          <i class="layui-icon layui-icon-more-vertical"></i>
        </a>
      </li>
    </ul>
  </div>

  <div class="layui-side layui-bg-black">
    <div class="layui-side-scroll">
      <!-- 左侧导航区域（可配合layui已有的垂直导航） -->
      <ul class="layui-nav layui-nav-tree layui-bg-cyan layui-inline" lay-filter="demo">
        <li class="layui-nav-item">
          <a  href="javascript:;">商品管理</a>
          <dl class="layui-nav-child">
            <dd><a th:href="@{/product/findAllGoods}" >商品基本信息</a></dd>
          </dl>
        </li>
      </ul>
      <ul class="layui-nav layui-nav-tree layui-bg-cyan layui-inline" lay-filter="demo">
        <li class="layui-nav-item">
          <a  href="javascript:;">购物车</a>
          <dl class="layui-nav-child">
            <dd><a th:href="@{/product/findAllShoppingCart}" >购物车</a></dd>
          </dl>
        </li>
      </ul>
    </div>
  </div>

  <div class="layui-body">
    <!-- 内容主体区域 -->
    <fieldset class="layui-elem-field layui-field-title" style="margin-top: 20px;">
      <legend>购物车信息</legend>
    </fieldset>


  <div id="cart">

    <table  border="1" cellpadding="0" width="900px" align="center">
      <tr>
        <th>商品图片</th>
        <th>商品id</th>
        <th>商品名</th>
        <th>商品单价</th>
        <th>商品描述</th>
        <th>商品件数</th>
        <th>总价</th>
      </tr>
      <tr th:each="goods:${goods}" align="center">
        <td width="200px"><input type="image" th:src="@{/imgs/witkey/chop.jpg}" class="chop"></td>
        <td th:text="${goods.id}"></td>
        <td th:text="${goods.name}"></td>
        <td th:text="${goods.price}"></td>
        <td th:text="${goods.describe}"></td>
        <td width="100px">
          <button class="reduce">-</button>
          <input type="text" th:value="${goods.count}" class="count">
          <button class="increase">+</button>
        </td>
        <td th:text="${goods.total}+元"></td>
      </tr>


    </table>
  </div>











    <div class="layui-footer">
      <!-- 底部固定区域 -->
      底部固定区域
    </div>
  </div>
</div>

  <script type="text/javascript" th:src="@{/layui/layui.js}"></script>
  <script type="text/javascript" th:src="@{/js/dateTime.js}"></script>
<script type="text/javascript" th:src="@{/js/phoenix/shoppingCartInfo.js}"></script>
  <script type="text/javascript" th:src="@{/js/jquery-1.8.3.min.js}"></script>
  <script type="text/javascript" th:src="@{/layer/layer.js}"></script>

  <script type="text/javascript">
    //显示实时时间
    $(function () {
      showDay();
      setInterval('showTime()');
    })
  </script>

</body>
</html>